package chapter09.p;

public class P11 {
	public static void process(String s) {
		char[] sp = s.toCharArray();
		StringBuffer buff = new StringBuffer();
		for (int i = 0; i < sp.length ; i = i+2) {
			if (i+1 < sp.length) {
				buff.append(sp[i+1]);
			}
			buff.append(sp[i]);
		}
		System.out.println(buff);
	}
	public static void main(String[] args) {
		String str = "abcdefg";
		process(str);
	}
}
